﻿<%@ Page Language="C#" MasterPageFile="~/admin/MasterPage_Admin.master" AutoEventWireup="true"
    CodeFile="副本 ads_position.aspx.cs" ValidateRequest="false" Inherits="admin_ads_position"
    Title="防骗数据库 - 广告信息管理 - By ECountry.Ltd" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder_Search" runat="Server">
    <asp:UpdatePanel ID="UpdatePanel2" runat="server">
        <ContentTemplate>
            <div style="width: 100%; text-align: center">
                <asp:Label ID="Label1" runat="server" Text="**综合广告信息管理中心**" Font-Bold="True" Font-Size="Large"
                    ForeColor="#000066"></asp:Label>
            </div>
            <%--               请选择广告位置类型：
            --%>
            <%--<asp:ObjectDataSource ID="ObjectDataSource_Ads_Type" runat="server" 
                OldValuesParameterFormatString="original_{0}" 
                SelectMethod="Get_Data_Order_By_Id" 
                TypeName="DataSet_fp_ads_DyhTableAdapters.Dyh_ADS_positionTableAdapter">
            </asp:ObjectDataSource>--%>
            <br>
            <asp:ListView ID="ListView1" runat="server" DataKeyNames="id" DataSourceID="ObjectDataSource1"
                InsertItemPosition="LastItem">
                <%--<AlternatingItemTemplate>
                    <tr style="">
                        <td>
                            <asp:Button ID="DeleteButton" runat="server" CommandName="Delete" Text="删除" />
                            <asp:Button ID="EditButton" runat="server" CommandName="Edit" Text="编辑" />
                        </td>
                        <td>
                            <asp:Label ID="idLabel" runat="server" Text='<%# Eval("id") %>' />
                        </td>
                        <td>
                            <asp:Label ID="positionLabel" runat="server" Text='<%# Eval("position") %>' />
                        </td>
                        <td>
                            <asp:Label ID="widthLabel" runat="server" Text='<%# Eval("width") %>' />
                        </td>
                        <td>
                            <asp:Label ID="heightLabel" runat="server" Text='<%# Eval("height") %>' />
                        </td>
                        <td>
                            <asp:Label ID="costLabel" runat="server" Text='<%# Eval("cost") %>' />
                        </td>
                        <td>
                            <asp:Label ID="descriptionLabel" runat="server" 
                                Text='<%# Eval("description") %>' />
                        </td>
                  </tr>
                </AlternatingItemTemplate>--%>
                <LayoutTemplate>
                    <table runat="server" width="100%">
                        <tr runat="server">
                            <td runat="server">
                                <table id="itemPlaceholderContainer" runat="server" border="1" style="background-color: #FFFFFF;
                                    border-collapse: collapse; border-color: #999999; border-style: none; border-width: 1px;
                                    font-family: Verdana, Arial, Helvetica, sans-serif; width: 100%;">
                                    <tr id="Tr1" runat="server" style="background-color: #E0FFFF; color: #333333;">
                                        <%--                                    <tr runat="server" style="">
                                        --%>
                                        <th runat="server">
                                        </th>
                                        <th runat="server">
                                            ID
                                        </th>
                                        <th runat="server">
                                            位置
                                        </th>
                                        <th runat="server">
                                            宽度
                                        </th>
                                        <th runat="server">
                                            高度
                                        </th>
                                        <th runat="server">
                                            价格
                                        </th>
                                        <th runat="server">
                                            说明
                                        </th>
                                        <%--<th runat="server">
                                            Delete_flag</th>--%>
                                    </tr>
                                    <tr id="itemPlaceholder" runat="server">
                                    </tr>
                                </table>
                            </td>
                        </tr>
                        <tr runat="server">
                            <td runat="server" style="">
                                <asp:DataPager ID="DataPager1" runat="server">
                                    <Fields>
                                        <asp:NextPreviousPagerField ButtonType="Button" ShowFirstPageButton="True" ShowLastPageButton="True" />
                                    </Fields>
                                </asp:DataPager>
                            </td>
                        </tr>
                    </table>
                </LayoutTemplate>
                <InsertItemTemplate>
                    <tr style="">
                        <td>
                            <asp:Button ID="InsertButton" runat="server" CommandName="Insert" Text="插入" />
                            <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" Text="清除" />
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            <asp:TextBox ID="positionTextBox" runat="server" Text='<%# Bind("position") %>' />
                        </td>
                        <td>
                            <asp:TextBox ID="widthTextBox" runat="server" Text='<%# Bind("width") %>' Width="60" />
                        </td>
                        <td>
                            <asp:TextBox ID="heightTextBox" runat="server" Text='<%# Bind("height") %>' Width="60" />
                        </td>
                        <td>
                            <asp:TextBox ID="costTextBox" runat="server" Text='<%# Bind("cost") %>' Width="80" />
                        </td>
                        <td>
                            <asp:TextBox ID="descriptionTextBox" runat="server" Text='<%# Bind("description") %>' />
                        </td>
                        <%--                        <td>
                            <asp:CheckBox ID="Delete_flagCheckBox" runat="server" 
                                Checked='<%# Bind("Delete_flag") %>' />
                        </td>
                        --%>
                    </tr>
                </InsertItemTemplate>
                <SelectedItemTemplate>
                    <tr style="">
                        <td>
                            <asp:Button ID="DeleteButton" runat="server" CommandName="Delete" Text="删除" />
                            <asp:Button ID="EditButton" runat="server" CommandName="Edit" Text="编辑" />
                        </td>
                        <td>
                            <asp:Label ID="idLabel" runat="server" Text='<%# Eval("id") %>' />
                        </td>
                        <td>
                            <asp:Label ID="positionLabel" runat="server" Text='<%# Eval("position") %>' />
                        </td>
                        <td>
                            <asp:Label ID="widthLabel" runat="server" Text='<%# Eval("width") %>' />
                        </td>
                        <td>
                            <asp:Label ID="heightLabel" runat="server" Text='<%# Eval("height") %>' />
                        </td>
                        <td>
                            <asp:Label ID="costLabel" runat="server" Text='<%# Eval("cost") %>' />
                        </td>
                        <td>
                            <asp:Label ID="descriptionLabel" runat="server" Text='<%# Eval("description") %>' />
                        </td>
                        <%--                        <td>
                            <asp:CheckBox ID="Delete_flagCheckBox" runat="server" 
                                Checked='<%# Eval("Delete_flag") %>' Enabled="false" />
                        </td>
                        --%>
                    </tr>
                </SelectedItemTemplate>
                <EmptyDataTemplate>
                    <table runat="server" style="">
                        <tr>
                            <td>
                                未返回数据。
                            </td>
                        </tr>
                    </table>
                </EmptyDataTemplate>
                <EditItemTemplate>
                    <tr style="">
                        <td>
                            <asp:Button ID="UpdateButton" runat="server" CommandName="Update" Text="更新" />
                            <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" Text="取消" />
                        </td>
                        <td>
                            <asp:Label ID="idLabel1" runat="server" Text='<%# Eval("id") %>' />
                        </td>
                        <td>
                            <asp:TextBox ID="positionTextBox" runat="server" Text='<%# Bind("position") %>' />
                        </td>
                        <td>
                            <asp:TextBox ID="widthTextBox" runat="server" Text='<%# Bind("width") %>' />
                        </td>
                        <td>
                            <asp:TextBox ID="heightTextBox" runat="server" Text='<%# Bind("height") %>' />
                        </td>
                        <td>
                            <asp:TextBox ID="costTextBox" runat="server" Text='<%# Bind("cost") %>' />
                        </td>
                        <td>
                            <asp:TextBox ID="descriptionTextBox" runat="server" Text='<%# Bind("description") %>' />
                        </td>
                        <td>
                            <asp:CheckBox ID="Delete_flagCheckBox" runat="server" Checked='<%# Bind("Delete_flag") %>' />
                        </td>
                    </tr>
                </EditItemTemplate>
                <ItemTemplate>
                    <tr style="">
                        <td style="width: 110px; text-align: center">
                            <asp:Button ID="DeleteButton" runat="server" CommandName="Delete" Text="删除" />
                            <asp:Button ID="EditButton" runat="server" CommandName="Edit" Text="编辑" />
                        </td>
                        <td style="width: 20px; text-align: center">
                            <asp:Label ID="idLabel" runat="server" Text='<%# Eval("id") %>' />
                        </td>
                        <td style="width: 90px; text-align: center">
                            <asp:Label ID="positionLabel" runat="server" Text='<%# Eval("position") %>' />
                        </td>
                        <td style="width: 60px; text-align: center">
                            <asp:Label ID="widthLabel" runat="server" Text='<%# Eval("width") %>' />
                        </td>
                        <td style="width: 60px; text-align: center">
                            <asp:Label ID="heightLabel" runat="server" Text='<%# Eval("height") %>' />
                        </td>
                        <td style="width: 90px; text-align: center">
                            <asp:Label ID="costLabel" runat="server" Text='<%# Eval("cost") %>' />
                        </td>
                        <td>
                            <asp:Label ID="descriptionLabel" runat="server" Text='<%# Eval("description") %>' />
                        </td>
                        <%--                        <td>
                            <asp:CheckBox ID="Delete_flagCheckBox" runat="server" 
                                Checked='<%# Eval("Delete_flag") %>' Enabled="false" />
                        </td>
                        --%>
                    </tr>
                </ItemTemplate>
            </asp:ListView>
            <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" DeleteMethod="Delete"
                InsertMethod="Insert" OldValuesParameterFormatString="original_{0}" SelectMethod="Get_Data_Order_By_Id"
                TypeName="DataSet_fp_ads_DyhTableAdapters.Dyh_ADS_positionTableAdapter" UpdateMethod="Update">
                <DeleteParameters>
                    <asp:Parameter Name="Original_id" Type="Int32" />
                </DeleteParameters>
                <UpdateParameters>
                    <asp:Parameter Name="position" Type="String" />
                    <asp:Parameter Name="width" Type="Int32" />
                    <asp:Parameter Name="height" Type="Int32" />
                    <asp:Parameter Name="cost" Type="Decimal" />
                    <asp:Parameter Name="description" Type="String" />
                    <asp:Parameter Name="Delete_flag" Type="Boolean" />
                    <asp:Parameter Name="Original_id" Type="Int32" />
                </UpdateParameters>
                <InsertParameters>
                    <asp:Parameter Name="position" Type="String" />
                    <asp:Parameter Name="width" Type="Int32" />
                    <asp:Parameter Name="height" Type="Int32" />
                    <asp:Parameter Name="cost" Type="Decimal" />
                    <asp:Parameter Name="description" Type="String" />
                    <asp:Parameter Name="Delete_flag" Type="Boolean" />
                </InsertParameters>
            </asp:ObjectDataSource>
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>
